package Users;


import entity.BookList;
import service.IOperation;

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public abstract class User {
    /**
     * 用户所有的操作权限
     */
    protected static List<IOperation> operations = new ArrayList<>();

    protected Scanner scanner = new Scanner(System.in);

    /**
     * 用户界面
     */
    public abstract int UI();

    public void operations(int select, BookList bookList) {
        operations.get(select - 1).work(bookList);
    }
}
